import React, { useCallback } from 'react';
import { ConfigProvider, Button, Space, DatePicker, version } from 'antd';

const App = () => {
  const handleClick = useCallback(() => {
    console.log('click');
  }, []);

  return (
    <ConfigProvider theme={{ token: { colorPrimary: '#00b96b' } }}>
      <div>
        <h1>App</h1>
        <div style={{ padding: '0 24px' }}>
          <h1>antd version: {version}</h1>
          <Space>
            <DatePicker />
            <Button
              type="primary"
              danger
              onClick={handleClick}>
              Primary Button
            </Button>
          </Space>
        </div>
      </div>
    </ConfigProvider>
  );
};

export default App;
